package com.wutianyi.module.product;

import com.wutianyi.module.product.dataobject.ProductInfoDO;
import com.wutianyi.module.product.mapper.ProductInfoMapper;

/**
 * @author wutianyi
 * 
 */
public class ProductInfoDaoMysqlImpl implements ProductInfoDao {

	private ProductInfoMapper productInfoMapper;

	@Override
	public ProductInfoDO getProductInfoByProductId(int productId) {
		return productInfoMapper.getProductInfoByProductId(productId);
	}

	@Override
	public int createProductInfo(ProductInfoDO productInfo) {
		return productInfoMapper.createProductInfo(productInfo);
	}

	public ProductInfoMapper getProductInfoMapper() {
		return productInfoMapper;
	}

	public void setProductInfoMapper(ProductInfoMapper productInfoMapper) {
		this.productInfoMapper = productInfoMapper;
	}

	@Override
	public int updateProductInfo(ProductInfoDO productInfo) {
		return productInfoMapper.updateProductInfo(productInfo);
	}

	@Override
	public int deleteProductInfo(int id) {
		return productInfoMapper.deleteProductInfo(id);
	}

}
